package co.edu.usbcali.scrum.presentation.businessDelegate;

import co.edu.usbcali.scrum.modelo.Actividades;
import co.edu.usbcali.scrum.modelo.Dailysprint;
import co.edu.usbcali.scrum.modelo.Empresa;
import co.edu.usbcali.scrum.modelo.Item;
import co.edu.usbcali.scrum.modelo.Persona;
import co.edu.usbcali.scrum.modelo.PersonaRol;
import co.edu.usbcali.scrum.modelo.PersonaRolId;
import co.edu.usbcali.scrum.modelo.ProductBacklog;
import co.edu.usbcali.scrum.modelo.Proyecto;
import co.edu.usbcali.scrum.modelo.RRetroexpectiva;
import co.edu.usbcali.scrum.modelo.Revision;
import co.edu.usbcali.scrum.modelo.Rol;
import co.edu.usbcali.scrum.modelo.Seguimiento;
import co.edu.usbcali.scrum.modelo.SeguimientoId;
import co.edu.usbcali.scrum.modelo.Springitem;
import co.edu.usbcali.scrum.modelo.SpringitemId;
import co.edu.usbcali.scrum.modelo.Sprint;
import co.edu.usbcali.scrum.modelo.SprintPlaning;
import co.edu.usbcali.scrum.modelo.control.ActividadesLogic;
import co.edu.usbcali.scrum.modelo.control.DailysprintLogic;
import co.edu.usbcali.scrum.modelo.control.EmpresaLogic;
import co.edu.usbcali.scrum.modelo.control.IActividadesLogic;
import co.edu.usbcali.scrum.modelo.control.IDailysprintLogic;
import co.edu.usbcali.scrum.modelo.control.IEmpresaLogic;
import co.edu.usbcali.scrum.modelo.control.IItemLogic;
import co.edu.usbcali.scrum.modelo.control.IPersonaLogic;
import co.edu.usbcali.scrum.modelo.control.IPersonaRolLogic;
import co.edu.usbcali.scrum.modelo.control.IProductBacklogLogic;
import co.edu.usbcali.scrum.modelo.control.IProyectoLogic;
import co.edu.usbcali.scrum.modelo.control.IRRetroexpectivaLogic;
import co.edu.usbcali.scrum.modelo.control.IRevisionLogic;
import co.edu.usbcali.scrum.modelo.control.IRolLogic;
import co.edu.usbcali.scrum.modelo.control.ISeguimientoLogic;
import co.edu.usbcali.scrum.modelo.control.ISpringitemLogic;
import co.edu.usbcali.scrum.modelo.control.ISprintLogic;
import co.edu.usbcali.scrum.modelo.control.ISprintPlaningLogic;
import co.edu.usbcali.scrum.modelo.control.ItemLogic;
import co.edu.usbcali.scrum.modelo.control.PersonaLogic;
import co.edu.usbcali.scrum.modelo.control.PersonaRolLogic;
import co.edu.usbcali.scrum.modelo.control.ProductBacklogLogic;
import co.edu.usbcali.scrum.modelo.control.ProyectoLogic;
import co.edu.usbcali.scrum.modelo.control.RRetroexpectivaLogic;
import co.edu.usbcali.scrum.modelo.control.RevisionLogic;
import co.edu.usbcali.scrum.modelo.control.RolLogic;
import co.edu.usbcali.scrum.modelo.control.SeguimientoLogic;
import co.edu.usbcali.scrum.modelo.control.SpringitemLogic;
import co.edu.usbcali.scrum.modelo.control.SprintLogic;
import co.edu.usbcali.scrum.modelo.control.SprintPlaningLogic;
import co.edu.usbcali.scrum.modelo.dto.*;

import java.math.BigDecimal;

import java.util.Date;
import java.util.List;
import java.util.Set;


/**
* Use a Business Delegate to reduce coupling between presentation-tier clients and business services.
* The Business Delegate hides the underlying implementation details of the business service, such as lookup and access details of the EJB architecture.
*
* The Business Delegate acts as a client-side business abstraction; it provides an abstraction for, and thus hides,
* the implementation of the business services. Using a Business Delegate reduces the coupling between presentation-tier clients and
* the system's business services. Depending on the implementation strategy, the Business Delegate may shield clients from possible
* volatility in the implementation of the business service API. Potentially, this reduces the number of changes that must be made to the
* presentation-tier client code when the business service API or its underlying implementation changes.
*
* However, interface methods in the Business Delegate may still require modification if the underlying business service API changes.
* Admittedly, though, it is more likely that changes will be made to the business service rather than to the Business Delegate.
*
* Often, developers are skeptical when a design goal such as abstracting the business layer causes additional upfront work in return
* for future gains. However, using this pattern or its strategies results in only a small amount of additional upfront work and provides
* considerable benefits. The main benefit is hiding the details of the underlying service. For example, the client can become transparent
* to naming and lookup services. The Business Delegate also handles the exceptions from the business services, such as java.rmi.Remote
* exceptions, Java Messages Service (JMS) exceptions and so on. The Business Delegate may intercept such service level exceptions and
* generate application level exceptions instead. Application level exceptions are easier to handle by the clients, and may be user friendly.
* The Business Delegate may also transparently perform any retry or recovery operations necessary in the event of a service failure without
* exposing the client to the problem until it is determined that the problem is not resolvable. These gains present a compelling reason to
* use the pattern.
*
* Another benefit is that the delegate may cache results and references to remote business services. Caching can significantly improve performance,
* because it limits unnecessary and potentially costly round trips over the network.
*
* A Business Delegate uses a component called the Lookup Service. The Lookup Service is responsible for hiding the underlying implementation
* details of the business service lookup code. The Lookup Service may be written as part of the Delegate, but we recommend that it be
* implemented as a separate component, as outlined in the Service Locator pattern (See "Service Locator" on page 368.)
*
* When the Business Delegate is used with a Session Facade, typically there is a one-to-one relationship between the two.
* This one-to-one relationship exists because logic that might have been encapsulated in a Business Delegate relating to its interaction
* with multiple business services (creating a one-to-many relationship) will often be factored back into a Session Facade.
*
* Finally, it should be noted that this pattern could be used to reduce coupling between other tiers, not simply the presentation and the
* business tiers.
*
* @author Zathura Code Generator http://code.google.com/p/zathura
*
*/
public class BusinessDelegatorView {
    private BusinessDelegatorView() {
    }

    public static List<Actividades> getActividades() throws Exception {
        IActividadesLogic actividadesLogic = new ActividadesLogic();

        return actividadesLogic.getActividades();
    }

    public static void saveActividades(String codigoAct, Date duracion,
        String estado, String nombre, String codigoItem_Item,
        String codigoPer_Persona) throws Exception {
        IActividadesLogic actividadesLogic = new ActividadesLogic();
        actividadesLogic.saveActividades(codigoAct, duracion, estado, nombre,
            codigoItem_Item, codigoPer_Persona);
    }

    public static void deleteActividades(String codigoAct)
        throws Exception {
        IActividadesLogic actividadesLogic = new ActividadesLogic();
        actividadesLogic.deleteActividades(codigoAct);
    }

    public static void updateActividades(String codigoAct, Date duracion,
        String estado, String nombre, String codigoItem_Item,
        String codigoPer_Persona) throws Exception {
        IActividadesLogic actividadesLogic = new ActividadesLogic();
        actividadesLogic.updateActividades(codigoAct, duracion, estado, nombre,
            codigoItem_Item, codigoPer_Persona);
    }

    public static Actividades getActividades(String codigoAct)
        throws Exception {
        IActividadesLogic actividadesLogic = new ActividadesLogic();
        Actividades actividades = null;

        try {
            actividades = actividadesLogic.getActividades(codigoAct);
        } catch (Exception e) {
            throw e;
        }

        return actividades;
    }

    public static List<Actividades> findByCriteriaInActividades(
        Object[] variables, Object[] variablesBetween,
        Object[] variablesBetweenDates) throws Exception {
        IActividadesLogic actividadesLogic = new ActividadesLogic();

        return actividadesLogic.findByCriteria(variables, variablesBetween,
            variablesBetweenDates);
    }

    public static List<Actividades> findPageActividades(String sortColumnName,
        boolean sortAscending, int startRow, int maxResults)
        throws Exception {
        IActividadesLogic actividadesLogic = new ActividadesLogic();

        return actividadesLogic.findPageActividades(sortColumnName,
            sortAscending, startRow, maxResults);
    }

    public static Long findTotalNumberActividades() throws Exception {
        IActividadesLogic actividadesLogic = new ActividadesLogic();

        return actividadesLogic.findTotalNumberActividades();
    }

    public static List<ActividadesDTO> getDataActividades()
        throws Exception {
        IActividadesLogic actividadesLogic = new ActividadesLogic();

        return actividadesLogic.getDataActividades();
    }

    public static List<Dailysprint> getDailysprint() throws Exception {
        IDailysprintLogic dailysprintLogic = new DailysprintLogic();

        return dailysprintLogic.getDailysprint();
    }

    public static void saveDailysprint(String codigoDaiSpr,
        String incovenientes, String codigoSprint_Sprint)
        throws Exception {
        IDailysprintLogic dailysprintLogic = new DailysprintLogic();
        dailysprintLogic.saveDailysprint(codigoDaiSpr, incovenientes,
            codigoSprint_Sprint);
    }

    public static void deleteDailysprint(String codigoDaiSpr)
        throws Exception {
        IDailysprintLogic dailysprintLogic = new DailysprintLogic();
        dailysprintLogic.deleteDailysprint(codigoDaiSpr);
    }

    public static void updateDailysprint(String codigoDaiSpr,
        String incovenientes, String codigoSprint_Sprint)
        throws Exception {
        IDailysprintLogic dailysprintLogic = new DailysprintLogic();
        dailysprintLogic.updateDailysprint(codigoDaiSpr, incovenientes,
            codigoSprint_Sprint);
    }

    public static Dailysprint getDailysprint(String codigoDaiSpr)
        throws Exception {
        IDailysprintLogic dailysprintLogic = new DailysprintLogic();
        Dailysprint dailysprint = null;

        try {
            dailysprint = dailysprintLogic.getDailysprint(codigoDaiSpr);
        } catch (Exception e) {
            throw e;
        }

        return dailysprint;
    }

    public static List<Dailysprint> findByCriteriaInDailysprint(
        Object[] variables, Object[] variablesBetween,
        Object[] variablesBetweenDates) throws Exception {
        IDailysprintLogic dailysprintLogic = new DailysprintLogic();

        return dailysprintLogic.findByCriteria(variables, variablesBetween,
            variablesBetweenDates);
    }

    public static List<Dailysprint> findPageDailysprint(String sortColumnName,
        boolean sortAscending, int startRow, int maxResults)
        throws Exception {
        IDailysprintLogic dailysprintLogic = new DailysprintLogic();

        return dailysprintLogic.findPageDailysprint(sortColumnName,
            sortAscending, startRow, maxResults);
    }

    public static Long findTotalNumberDailysprint() throws Exception {
        IDailysprintLogic dailysprintLogic = new DailysprintLogic();

        return dailysprintLogic.findTotalNumberDailysprint();
    }

    public static List<DailysprintDTO> getDataDailysprint()
        throws Exception {
        IDailysprintLogic dailysprintLogic = new DailysprintLogic();

        return dailysprintLogic.getDataDailysprint();
    }

    public static List<Empresa> getEmpresa() throws Exception {
        IEmpresaLogic empresaLogic = new EmpresaLogic();

        return empresaLogic.getEmpresa();
    }

    public static void saveEmpresa(String celular, String codigoEmp,
        String correo, String direccion, String estado, String nombre)
        throws Exception {
        IEmpresaLogic empresaLogic = new EmpresaLogic();
        empresaLogic.saveEmpresa(celular, codigoEmp, correo, direccion, estado,
            nombre);
    }

    public static void deleteEmpresa(String codigoEmp)
        throws Exception {
        IEmpresaLogic empresaLogic = new EmpresaLogic();
        empresaLogic.deleteEmpresa(codigoEmp);
    }

    public static void updateEmpresa(String celular, String codigoEmp,
        String correo, String direccion, String estado, String nombre)
        throws Exception {
        IEmpresaLogic empresaLogic = new EmpresaLogic();
        empresaLogic.updateEmpresa(celular, codigoEmp, correo, direccion,
            estado, nombre);
    }

    public static Empresa getEmpresa(String codigoEmp)
        throws Exception {
        IEmpresaLogic empresaLogic = new EmpresaLogic();
        Empresa empresa = null;

        try {
            empresa = empresaLogic.getEmpresa(codigoEmp);
        } catch (Exception e) {
            throw e;
        }

        return empresa;
    }

    public static List<Empresa> findByCriteriaInEmpresa(Object[] variables,
        Object[] variablesBetween, Object[] variablesBetweenDates)
        throws Exception {
        IEmpresaLogic empresaLogic = new EmpresaLogic();

        return empresaLogic.findByCriteria(variables, variablesBetween,
            variablesBetweenDates);
    }

    public static List<Empresa> findPageEmpresa(String sortColumnName,
        boolean sortAscending, int startRow, int maxResults)
        throws Exception {
        IEmpresaLogic empresaLogic = new EmpresaLogic();

        return empresaLogic.findPageEmpresa(sortColumnName, sortAscending,
            startRow, maxResults);
    }

    public static Long findTotalNumberEmpresa() throws Exception {
        IEmpresaLogic empresaLogic = new EmpresaLogic();

        return empresaLogic.findTotalNumberEmpresa();
    }

    public static List<EmpresaDTO> getDataEmpresa() throws Exception {
        IEmpresaLogic empresaLogic = new EmpresaLogic();

        return empresaLogic.getDataEmpresa();
    }

    public static List<Item> getItem() throws Exception {
        IItemLogic itemLogic = new ItemLogic();

        return itemLogic.getItem();
    }

    public static void saveItem(String codigoItem, String estado,
        String nombre, String codigoProBack_ProductBacklog)
        throws Exception {
        IItemLogic itemLogic = new ItemLogic();
        itemLogic.saveItem(codigoItem, estado, nombre,
            codigoProBack_ProductBacklog);
    }

    public static void deleteItem(String codigoItem) throws Exception {
        IItemLogic itemLogic = new ItemLogic();
        itemLogic.deleteItem(codigoItem);
    }

    public static void updateItem(String codigoItem, String estado,
        String nombre, String codigoProBack_ProductBacklog)
        throws Exception {
        IItemLogic itemLogic = new ItemLogic();
        itemLogic.updateItem(codigoItem, estado, nombre,
            codigoProBack_ProductBacklog);
    }

    public static Item getItem(String codigoItem) throws Exception {
        IItemLogic itemLogic = new ItemLogic();
        Item item = null;

        try {
            item = itemLogic.getItem(codigoItem);
        } catch (Exception e) {
            throw e;
        }

        return item;
    }

    public static List<Item> findByCriteriaInItem(Object[] variables,
        Object[] variablesBetween, Object[] variablesBetweenDates)
        throws Exception {
        IItemLogic itemLogic = new ItemLogic();

        return itemLogic.findByCriteria(variables, variablesBetween,
            variablesBetweenDates);
    }

    public static List<Item> findPageItem(String sortColumnName,
        boolean sortAscending, int startRow, int maxResults)
        throws Exception {
        IItemLogic itemLogic = new ItemLogic();

        return itemLogic.findPageItem(sortColumnName, sortAscending, startRow,
            maxResults);
    }

    public static Long findTotalNumberItem() throws Exception {
        IItemLogic itemLogic = new ItemLogic();

        return itemLogic.findTotalNumberItem();
    }

    public static List<ItemDTO> getDataItem() throws Exception {
        IItemLogic itemLogic = new ItemLogic();

        return itemLogic.getDataItem();
    }

    public static List<Persona> getPersona() throws Exception {
        IPersonaLogic personaLogic = new PersonaLogic();

        return personaLogic.getPersona();
    }

    public static void savePersona(String celular, String clave,
        String codigoPer, String correo, String estado, String nombre,
        String usuario, String codigoEmp_Empresa) throws Exception {
        IPersonaLogic personaLogic = new PersonaLogic();
        personaLogic.savePersona(celular, clave, codigoPer, correo, estado,
            nombre, usuario, codigoEmp_Empresa);
    }

    public static void deletePersona(String codigoPer)
        throws Exception {
        IPersonaLogic personaLogic = new PersonaLogic();
        personaLogic.deletePersona(codigoPer);
    }

    public static void updatePersona(String celular, String clave,
        String codigoPer, String correo, String estado, String nombre,
        String usuario, String codigoEmp_Empresa) throws Exception {
        IPersonaLogic personaLogic = new PersonaLogic();
        personaLogic.updatePersona(celular, clave, codigoPer, correo, estado,
            nombre, usuario, codigoEmp_Empresa);
    }

    public static Persona getPersona(String codigoPer)
        throws Exception {
        IPersonaLogic personaLogic = new PersonaLogic();
        Persona persona = null;

        try {
            persona = personaLogic.getPersona(codigoPer);
        } catch (Exception e) {
            throw e;
        }

        return persona;
    }

    public static List<Persona> findByCriteriaInPersona(Object[] variables,
        Object[] variablesBetween, Object[] variablesBetweenDates)
        throws Exception {
        IPersonaLogic personaLogic = new PersonaLogic();

        return personaLogic.findByCriteria(variables, variablesBetween,
            variablesBetweenDates);
    }

    public static List<Persona> findPagePersona(String sortColumnName,
        boolean sortAscending, int startRow, int maxResults)
        throws Exception {
        IPersonaLogic personaLogic = new PersonaLogic();

        return personaLogic.findPagePersona(sortColumnName, sortAscending,
            startRow, maxResults);
    }

    public static Long findTotalNumberPersona() throws Exception {
        IPersonaLogic personaLogic = new PersonaLogic();

        return personaLogic.findTotalNumberPersona();
    }

    public static List<PersonaDTO> getDataPersona() throws Exception {
        IPersonaLogic personaLogic = new PersonaLogic();

        return personaLogic.getDataPersona();
    }

    public static List<PersonaRol> getPersonaRol() throws Exception {
        IPersonaRolLogic personaRolLogic = new PersonaRolLogic();

        return personaRolLogic.getPersonaRol();
    }

    public static void savePersonaRol(String codigoPer, String codigoRol,
        String codigoPro, String codigoPer_Persona, String codigoPro_Proyecto,
        String codigoRol_Rol) throws Exception {
        IPersonaRolLogic personaRolLogic = new PersonaRolLogic();
        personaRolLogic.savePersonaRol(codigoPer, codigoRol, codigoPro,
            codigoPer_Persona, codigoPro_Proyecto, codigoRol_Rol);
    }

    public static void deletePersonaRol(String codigoPer, String codigoRol,
        String codigoPro) throws Exception {
        IPersonaRolLogic personaRolLogic = new PersonaRolLogic();
        personaRolLogic.deletePersonaRol(codigoPer, codigoRol, codigoPro);
    }

    public static void updatePersonaRol(String codigoPer, String codigoRol,
        String codigoPro, String codigoPer_Persona, String codigoPro_Proyecto,
        String codigoRol_Rol) throws Exception {
        IPersonaRolLogic personaRolLogic = new PersonaRolLogic();
        personaRolLogic.updatePersonaRol(codigoPer, codigoRol, codigoPro,
            codigoPer_Persona, codigoPro_Proyecto, codigoRol_Rol);
    }

    public static PersonaRol getPersonaRol(PersonaRolId id)
        throws Exception {
        IPersonaRolLogic personaRolLogic = new PersonaRolLogic();
        PersonaRol personaRol = null;

        try {
            personaRol = personaRolLogic.getPersonaRol(id);
        } catch (Exception e) {
            throw e;
        }

        return personaRol;
    }

    public static List<PersonaRol> findByCriteriaInPersonaRol(
        Object[] variables, Object[] variablesBetween,
        Object[] variablesBetweenDates) throws Exception {
        IPersonaRolLogic personaRolLogic = new PersonaRolLogic();

        return personaRolLogic.findByCriteria(variables, variablesBetween,
            variablesBetweenDates);
    }

    public static List<PersonaRol> findPagePersonaRol(String sortColumnName,
        boolean sortAscending, int startRow, int maxResults)
        throws Exception {
        IPersonaRolLogic personaRolLogic = new PersonaRolLogic();

        return personaRolLogic.findPagePersonaRol(sortColumnName,
            sortAscending, startRow, maxResults);
    }

    public static Long findTotalNumberPersonaRol() throws Exception {
        IPersonaRolLogic personaRolLogic = new PersonaRolLogic();

        return personaRolLogic.findTotalNumberPersonaRol();
    }

    public static List<PersonaRolDTO> getDataPersonaRol()
        throws Exception {
        IPersonaRolLogic personaRolLogic = new PersonaRolLogic();

        return personaRolLogic.getDataPersonaRol();
    }

    public static List<ProductBacklog> getProductBacklog()
        throws Exception {
        IProductBacklogLogic productBacklogLogic = new ProductBacklogLogic();

        return productBacklogLogic.getProductBacklog();
    }

    public static void saveProductBacklog(String codigoProBack, String estado,
        String codigoPro_Proyecto) throws Exception {
        IProductBacklogLogic productBacklogLogic = new ProductBacklogLogic();
        productBacklogLogic.saveProductBacklog(codigoProBack, estado,
            codigoPro_Proyecto);
    }

    public static void deleteProductBacklog(String codigoProBack)
        throws Exception {
        IProductBacklogLogic productBacklogLogic = new ProductBacklogLogic();
        productBacklogLogic.deleteProductBacklog(codigoProBack);
    }

    public static void updateProductBacklog(String codigoProBack,
        String estado, String codigoPro_Proyecto) throws Exception {
        IProductBacklogLogic productBacklogLogic = new ProductBacklogLogic();
        productBacklogLogic.updateProductBacklog(codigoProBack, estado,
            codigoPro_Proyecto);
    }

    public static ProductBacklog getProductBacklog(String codigoProBack)
        throws Exception {
        IProductBacklogLogic productBacklogLogic = new ProductBacklogLogic();
        ProductBacklog productBacklog = null;

        try {
            productBacklog = productBacklogLogic.getProductBacklog(codigoProBack);
        } catch (Exception e) {
            throw e;
        }

        return productBacklog;
    }

    public static List<ProductBacklog> findByCriteriaInProductBacklog(
        Object[] variables, Object[] variablesBetween,
        Object[] variablesBetweenDates) throws Exception {
        IProductBacklogLogic productBacklogLogic = new ProductBacklogLogic();

        return productBacklogLogic.findByCriteria(variables, variablesBetween,
            variablesBetweenDates);
    }

    public static List<ProductBacklog> findPageProductBacklog(
        String sortColumnName, boolean sortAscending, int startRow,
        int maxResults) throws Exception {
        IProductBacklogLogic productBacklogLogic = new ProductBacklogLogic();

        return productBacklogLogic.findPageProductBacklog(sortColumnName,
            sortAscending, startRow, maxResults);
    }

    public static Long findTotalNumberProductBacklog()
        throws Exception {
        IProductBacklogLogic productBacklogLogic = new ProductBacklogLogic();

        return productBacklogLogic.findTotalNumberProductBacklog();
    }

    public static List<ProductBacklogDTO> getDataProductBacklog()
        throws Exception {
        IProductBacklogLogic productBacklogLogic = new ProductBacklogLogic();

        return productBacklogLogic.getDataProductBacklog();
    }

    public static List<Proyecto> getProyecto() throws Exception {
        IProyectoLogic proyectoLogic = new ProyectoLogic();

        return proyectoLogic.getProyecto();
    }

    public static void saveProyecto(String codigoPro, String estado,
        String nombre, String codigoEmp_Empresa) throws Exception {
        IProyectoLogic proyectoLogic = new ProyectoLogic();
        proyectoLogic.saveProyecto(codigoPro, estado, nombre, codigoEmp_Empresa);
    }

    public static void deleteProyecto(String codigoPro)
        throws Exception {
        IProyectoLogic proyectoLogic = new ProyectoLogic();
        proyectoLogic.deleteProyecto(codigoPro);
    }

    public static void updateProyecto(String codigoPro, String estado,
        String nombre, String codigoEmp_Empresa) throws Exception {
        IProyectoLogic proyectoLogic = new ProyectoLogic();
        proyectoLogic.updateProyecto(codigoPro, estado, nombre,
            codigoEmp_Empresa);
    }

    public static Proyecto getProyecto(String codigoPro)
        throws Exception {
        IProyectoLogic proyectoLogic = new ProyectoLogic();
        Proyecto proyecto = null;

        try {
            proyecto = proyectoLogic.getProyecto(codigoPro);
        } catch (Exception e) {
            throw e;
        }

        return proyecto;
    }

    public static List<Proyecto> findByCriteriaInProyecto(Object[] variables,
        Object[] variablesBetween, Object[] variablesBetweenDates)
        throws Exception {
        IProyectoLogic proyectoLogic = new ProyectoLogic();

        return proyectoLogic.findByCriteria(variables, variablesBetween,
            variablesBetweenDates);
    }

    public static List<Proyecto> findPageProyecto(String sortColumnName,
        boolean sortAscending, int startRow, int maxResults)
        throws Exception {
        IProyectoLogic proyectoLogic = new ProyectoLogic();

        return proyectoLogic.findPageProyecto(sortColumnName, sortAscending,
            startRow, maxResults);
    }

    public static Long findTotalNumberProyecto() throws Exception {
        IProyectoLogic proyectoLogic = new ProyectoLogic();

        return proyectoLogic.findTotalNumberProyecto();
    }

    public static List<ProyectoDTO> getDataProyecto() throws Exception {
        IProyectoLogic proyectoLogic = new ProyectoLogic();

        return proyectoLogic.getDataProyecto();
    }

    public static List<Revision> getRevision() throws Exception {
        IRevisionLogic revisionLogic = new RevisionLogic();

        return revisionLogic.getRevision();
    }

    public static void saveRevision(String codigoRev, String estado,
        Date fechaCreacion, Date fechaModificacion, String codigoSprint_Sprint)
        throws Exception {
        IRevisionLogic revisionLogic = new RevisionLogic();
        revisionLogic.saveRevision(codigoRev, estado, fechaCreacion,
            fechaModificacion, codigoSprint_Sprint);
    }

    public static void deleteRevision(String codigoRev)
        throws Exception {
        IRevisionLogic revisionLogic = new RevisionLogic();
        revisionLogic.deleteRevision(codigoRev);
    }

    public static void updateRevision(String codigoRev, String estado,
        Date fechaCreacion, Date fechaModificacion, String codigoSprint_Sprint)
        throws Exception {
        IRevisionLogic revisionLogic = new RevisionLogic();
        revisionLogic.updateRevision(codigoRev, estado, fechaCreacion,
            fechaModificacion, codigoSprint_Sprint);
    }

    public static Revision getRevision(String codigoRev)
        throws Exception {
        IRevisionLogic revisionLogic = new RevisionLogic();
        Revision revision = null;

        try {
            revision = revisionLogic.getRevision(codigoRev);
        } catch (Exception e) {
            throw e;
        }

        return revision;
    }

    public static List<Revision> findByCriteriaInRevision(Object[] variables,
        Object[] variablesBetween, Object[] variablesBetweenDates)
        throws Exception {
        IRevisionLogic revisionLogic = new RevisionLogic();

        return revisionLogic.findByCriteria(variables, variablesBetween,
            variablesBetweenDates);
    }

    public static List<Revision> findPageRevision(String sortColumnName,
        boolean sortAscending, int startRow, int maxResults)
        throws Exception {
        IRevisionLogic revisionLogic = new RevisionLogic();

        return revisionLogic.findPageRevision(sortColumnName, sortAscending,
            startRow, maxResults);
    }

    public static Long findTotalNumberRevision() throws Exception {
        IRevisionLogic revisionLogic = new RevisionLogic();

        return revisionLogic.findTotalNumberRevision();
    }

    public static List<RevisionDTO> getDataRevision() throws Exception {
        IRevisionLogic revisionLogic = new RevisionLogic();

        return revisionLogic.getDataRevision();
    }

    public static List<Rol> getRol() throws Exception {
        IRolLogic rolLogic = new RolLogic();

        return rolLogic.getRol();
    }

    public static void saveRol(String codigoRol, String estado, String nombre)
        throws Exception {
        IRolLogic rolLogic = new RolLogic();
        rolLogic.saveRol(codigoRol, estado, nombre);
    }

    public static void deleteRol(String codigoRol) throws Exception {
        IRolLogic rolLogic = new RolLogic();
        rolLogic.deleteRol(codigoRol);
    }

    public static void updateRol(String codigoRol, String estado, String nombre)
        throws Exception {
        IRolLogic rolLogic = new RolLogic();
        rolLogic.updateRol(codigoRol, estado, nombre);
    }

    public static Rol getRol(String codigoRol) throws Exception {
        IRolLogic rolLogic = new RolLogic();
        Rol rol = null;

        try {
            rol = rolLogic.getRol(codigoRol);
        } catch (Exception e) {
            throw e;
        }

        return rol;
    }

    public static List<Rol> findByCriteriaInRol(Object[] variables,
        Object[] variablesBetween, Object[] variablesBetweenDates)
        throws Exception {
        IRolLogic rolLogic = new RolLogic();

        return rolLogic.findByCriteria(variables, variablesBetween,
            variablesBetweenDates);
    }

    public static List<Rol> findPageRol(String sortColumnName,
        boolean sortAscending, int startRow, int maxResults)
        throws Exception {
        IRolLogic rolLogic = new RolLogic();

        return rolLogic.findPageRol(sortColumnName, sortAscending, startRow,
            maxResults);
    }

    public static Long findTotalNumberRol() throws Exception {
        IRolLogic rolLogic = new RolLogic();

        return rolLogic.findTotalNumberRol();
    }

    public static List<RolDTO> getDataRol() throws Exception {
        IRolLogic rolLogic = new RolLogic();

        return rolLogic.getDataRol();
    }

    public static List<RRetroexpectiva> getRRetroexpectiva()
        throws Exception {
        IRRetroexpectivaLogic rRetroexpectivaLogic = new RRetroexpectivaLogic();

        return rRetroexpectivaLogic.getRRetroexpectiva();
    }

    public static void saveRRetroexpectiva(String codigoRet, String estado,
        Date fechaCreacion, Date fechaModificacion, String codigoSprint_Sprint)
        throws Exception {
        IRRetroexpectivaLogic rRetroexpectivaLogic = new RRetroexpectivaLogic();
        rRetroexpectivaLogic.saveRRetroexpectiva(codigoRet, estado,
            fechaCreacion, fechaModificacion, codigoSprint_Sprint);
    }

    public static void deleteRRetroexpectiva(String codigoRet)
        throws Exception {
        IRRetroexpectivaLogic rRetroexpectivaLogic = new RRetroexpectivaLogic();
        rRetroexpectivaLogic.deleteRRetroexpectiva(codigoRet);
    }

    public static void updateRRetroexpectiva(String codigoRet, String estado,
        Date fechaCreacion, Date fechaModificacion, String codigoSprint_Sprint)
        throws Exception {
        IRRetroexpectivaLogic rRetroexpectivaLogic = new RRetroexpectivaLogic();
        rRetroexpectivaLogic.updateRRetroexpectiva(codigoRet, estado,
            fechaCreacion, fechaModificacion, codigoSprint_Sprint);
    }

    public static RRetroexpectiva getRRetroexpectiva(String codigoRet)
        throws Exception {
        IRRetroexpectivaLogic rRetroexpectivaLogic = new RRetroexpectivaLogic();
        RRetroexpectiva rRetroexpectiva = null;

        try {
            rRetroexpectiva = rRetroexpectivaLogic.getRRetroexpectiva(codigoRet);
        } catch (Exception e) {
            throw e;
        }

        return rRetroexpectiva;
    }

    public static List<RRetroexpectiva> findByCriteriaInRRetroexpectiva(
        Object[] variables, Object[] variablesBetween,
        Object[] variablesBetweenDates) throws Exception {
        IRRetroexpectivaLogic rRetroexpectivaLogic = new RRetroexpectivaLogic();

        return rRetroexpectivaLogic.findByCriteria(variables, variablesBetween,
            variablesBetweenDates);
    }

    public static List<RRetroexpectiva> findPageRRetroexpectiva(
        String sortColumnName, boolean sortAscending, int startRow,
        int maxResults) throws Exception {
        IRRetroexpectivaLogic rRetroexpectivaLogic = new RRetroexpectivaLogic();

        return rRetroexpectivaLogic.findPageRRetroexpectiva(sortColumnName,
            sortAscending, startRow, maxResults);
    }

    public static Long findTotalNumberRRetroexpectiva()
        throws Exception {
        IRRetroexpectivaLogic rRetroexpectivaLogic = new RRetroexpectivaLogic();

        return rRetroexpectivaLogic.findTotalNumberRRetroexpectiva();
    }

    public static List<RRetroexpectivaDTO> getDataRRetroexpectiva()
        throws Exception {
        IRRetroexpectivaLogic rRetroexpectivaLogic = new RRetroexpectivaLogic();

        return rRetroexpectivaLogic.getDataRRetroexpectiva();
    }

    public static List<Seguimiento> getSeguimiento() throws Exception {
        ISeguimientoLogic seguimientoLogic = new SeguimientoLogic();

        return seguimientoLogic.getSeguimiento();
    }

    public static void saveSeguimiento(String codigoDaiSpr, String codigoAct,
        String codigoAct_Actividades, String codigoDaiSpr_Dailysprint)
        throws Exception {
        ISeguimientoLogic seguimientoLogic = new SeguimientoLogic();
        seguimientoLogic.saveSeguimiento(codigoDaiSpr, codigoAct,
            codigoAct_Actividades, codigoDaiSpr_Dailysprint);
    }

    public static void deleteSeguimiento(String codigoDaiSpr, String codigoAct)
        throws Exception {
        ISeguimientoLogic seguimientoLogic = new SeguimientoLogic();
        seguimientoLogic.deleteSeguimiento(codigoDaiSpr, codigoAct);
    }

    public static void updateSeguimiento(String codigoDaiSpr, String codigoAct,
        String codigoAct_Actividades, String codigoDaiSpr_Dailysprint)
        throws Exception {
        ISeguimientoLogic seguimientoLogic = new SeguimientoLogic();
        seguimientoLogic.updateSeguimiento(codigoDaiSpr, codigoAct,
            codigoAct_Actividades, codigoDaiSpr_Dailysprint);
    }

    public static Seguimiento getSeguimiento(SeguimientoId id)
        throws Exception {
        ISeguimientoLogic seguimientoLogic = new SeguimientoLogic();
        Seguimiento seguimiento = null;

        try {
            seguimiento = seguimientoLogic.getSeguimiento(id);
        } catch (Exception e) {
            throw e;
        }

        return seguimiento;
    }

    public static List<Seguimiento> findByCriteriaInSeguimiento(
        Object[] variables, Object[] variablesBetween,
        Object[] variablesBetweenDates) throws Exception {
        ISeguimientoLogic seguimientoLogic = new SeguimientoLogic();

        return seguimientoLogic.findByCriteria(variables, variablesBetween,
            variablesBetweenDates);
    }

    public static List<Seguimiento> findPageSeguimiento(String sortColumnName,
        boolean sortAscending, int startRow, int maxResults)
        throws Exception {
        ISeguimientoLogic seguimientoLogic = new SeguimientoLogic();

        return seguimientoLogic.findPageSeguimiento(sortColumnName,
            sortAscending, startRow, maxResults);
    }

    public static Long findTotalNumberSeguimiento() throws Exception {
        ISeguimientoLogic seguimientoLogic = new SeguimientoLogic();

        return seguimientoLogic.findTotalNumberSeguimiento();
    }

    public static List<SeguimientoDTO> getDataSeguimiento()
        throws Exception {
        ISeguimientoLogic seguimientoLogic = new SeguimientoLogic();

        return seguimientoLogic.getDataSeguimiento();
    }

    public static List<Springitem> getSpringitem() throws Exception {
        ISpringitemLogic springitemLogic = new SpringitemLogic();

        return springitemLogic.getSpringitem();
    }

    public static void saveSpringitem(String codigoSprint, String codigoItem,
        String codigoItem_Item, String codigoSprint_Sprint)
        throws Exception {
        ISpringitemLogic springitemLogic = new SpringitemLogic();
        springitemLogic.saveSpringitem(codigoSprint, codigoItem,
            codigoItem_Item, codigoSprint_Sprint);
    }

    public static void deleteSpringitem(String codigoSprint, String codigoItem)
        throws Exception {
        ISpringitemLogic springitemLogic = new SpringitemLogic();
        springitemLogic.deleteSpringitem(codigoSprint, codigoItem);
    }

    public static void updateSpringitem(String codigoSprint, String codigoItem,
        String codigoItem_Item, String codigoSprint_Sprint)
        throws Exception {
        ISpringitemLogic springitemLogic = new SpringitemLogic();
        springitemLogic.updateSpringitem(codigoSprint, codigoItem,
            codigoItem_Item, codigoSprint_Sprint);
    }

    public static Springitem getSpringitem(SpringitemId id)
        throws Exception {
        ISpringitemLogic springitemLogic = new SpringitemLogic();
        Springitem springitem = null;

        try {
            springitem = springitemLogic.getSpringitem(id);
        } catch (Exception e) {
            throw e;
        }

        return springitem;
    }

    public static List<Springitem> findByCriteriaInSpringitem(
        Object[] variables, Object[] variablesBetween,
        Object[] variablesBetweenDates) throws Exception {
        ISpringitemLogic springitemLogic = new SpringitemLogic();

        return springitemLogic.findByCriteria(variables, variablesBetween,
            variablesBetweenDates);
    }

    public static List<Springitem> findPageSpringitem(String sortColumnName,
        boolean sortAscending, int startRow, int maxResults)
        throws Exception {
        ISpringitemLogic springitemLogic = new SpringitemLogic();

        return springitemLogic.findPageSpringitem(sortColumnName,
            sortAscending, startRow, maxResults);
    }

    public static Long findTotalNumberSpringitem() throws Exception {
        ISpringitemLogic springitemLogic = new SpringitemLogic();

        return springitemLogic.findTotalNumberSpringitem();
    }

    public static List<SpringitemDTO> getDataSpringitem()
        throws Exception {
        ISpringitemLogic springitemLogic = new SpringitemLogic();

        return springitemLogic.getDataSpringitem();
    }

    public static List<Sprint> getSprint() throws Exception {
        ISprintLogic sprintLogic = new SprintLogic();

        return sprintLogic.getSprint();
    }

    public static void saveSprint(String codigoSprint, Date duracion,
        String estado, Date fechaCreacion, Date fechaModificacion,
        String codigoPro_Proyecto) throws Exception {
        ISprintLogic sprintLogic = new SprintLogic();
        sprintLogic.saveSprint(codigoSprint, duracion, estado, fechaCreacion,
            fechaModificacion, codigoPro_Proyecto);
    }

    public static void deleteSprint(String codigoSprint)
        throws Exception {
        ISprintLogic sprintLogic = new SprintLogic();
        sprintLogic.deleteSprint(codigoSprint);
    }

    public static void updateSprint(String codigoSprint, Date duracion,
        String estado, Date fechaCreacion, Date fechaModificacion,
        String codigoPro_Proyecto) throws Exception {
        ISprintLogic sprintLogic = new SprintLogic();
        sprintLogic.updateSprint(codigoSprint, duracion, estado, fechaCreacion,
            fechaModificacion, codigoPro_Proyecto);
    }

    public static Sprint getSprint(String codigoSprint)
        throws Exception {
        ISprintLogic sprintLogic = new SprintLogic();
        Sprint sprint = null;

        try {
            sprint = sprintLogic.getSprint(codigoSprint);
        } catch (Exception e) {
            throw e;
        }

        return sprint;
    }

    public static List<Sprint> findByCriteriaInSprint(Object[] variables,
        Object[] variablesBetween, Object[] variablesBetweenDates)
        throws Exception {
        ISprintLogic sprintLogic = new SprintLogic();

        return sprintLogic.findByCriteria(variables, variablesBetween,
            variablesBetweenDates);
    }

    public static List<Sprint> findPageSprint(String sortColumnName,
        boolean sortAscending, int startRow, int maxResults)
        throws Exception {
        ISprintLogic sprintLogic = new SprintLogic();

        return sprintLogic.findPageSprint(sortColumnName, sortAscending,
            startRow, maxResults);
    }

    public static Long findTotalNumberSprint() throws Exception {
        ISprintLogic sprintLogic = new SprintLogic();

        return sprintLogic.findTotalNumberSprint();
    }

    public static List<SprintDTO> getDataSprint() throws Exception {
        ISprintLogic sprintLogic = new SprintLogic();

        return sprintLogic.getDataSprint();
    }

    public static List<SprintPlaning> getSprintPlaning()
        throws Exception {
        ISprintPlaningLogic sprintPlaningLogic = new SprintPlaningLogic();

        return sprintPlaningLogic.getSprintPlaning();
    }

    public static void saveSprintPlaning(String codigoSpPla, String estado,
        Date fechaCreacion, Date fechaModificacion, String codigoPro_Proyecto)
        throws Exception {
        ISprintPlaningLogic sprintPlaningLogic = new SprintPlaningLogic();
        sprintPlaningLogic.saveSprintPlaning(codigoSpPla, estado,
            fechaCreacion, fechaModificacion, codigoPro_Proyecto);
    }

    public static void deleteSprintPlaning(String codigoSpPla)
        throws Exception {
        ISprintPlaningLogic sprintPlaningLogic = new SprintPlaningLogic();
        sprintPlaningLogic.deleteSprintPlaning(codigoSpPla);
    }

    public static void updateSprintPlaning(String codigoSpPla, String estado,
        Date fechaCreacion, Date fechaModificacion, String codigoPro_Proyecto)
        throws Exception {
        ISprintPlaningLogic sprintPlaningLogic = new SprintPlaningLogic();
        sprintPlaningLogic.updateSprintPlaning(codigoSpPla, estado,
            fechaCreacion, fechaModificacion, codigoPro_Proyecto);
    }

    public static SprintPlaning getSprintPlaning(String codigoSpPla)
        throws Exception {
        ISprintPlaningLogic sprintPlaningLogic = new SprintPlaningLogic();
        SprintPlaning sprintPlaning = null;

        try {
            sprintPlaning = sprintPlaningLogic.getSprintPlaning(codigoSpPla);
        } catch (Exception e) {
            throw e;
        }

        return sprintPlaning;
    }

    public static List<SprintPlaning> findByCriteriaInSprintPlaning(
        Object[] variables, Object[] variablesBetween,
        Object[] variablesBetweenDates) throws Exception {
        ISprintPlaningLogic sprintPlaningLogic = new SprintPlaningLogic();

        return sprintPlaningLogic.findByCriteria(variables, variablesBetween,
            variablesBetweenDates);
    }

    public static List<SprintPlaning> findPageSprintPlaning(
        String sortColumnName, boolean sortAscending, int startRow,
        int maxResults) throws Exception {
        ISprintPlaningLogic sprintPlaningLogic = new SprintPlaningLogic();

        return sprintPlaningLogic.findPageSprintPlaning(sortColumnName,
            sortAscending, startRow, maxResults);
    }

    public static Long findTotalNumberSprintPlaning() throws Exception {
        ISprintPlaningLogic sprintPlaningLogic = new SprintPlaningLogic();

        return sprintPlaningLogic.findTotalNumberSprintPlaning();
    }

    public static List<SprintPlaningDTO> getDataSprintPlaning()
        throws Exception {
        ISprintPlaningLogic sprintPlaningLogic = new SprintPlaningLogic();

        return sprintPlaningLogic.getDataSprintPlaning();
    }
}
